package map;

import java.awt.Graphics;
import java.awt.image.BufferedImage;
import javax.imageio.ImageIO;

/**
 * @Lớp vật cản, cây cối,...
 */
public class Tree {

    private BufferedImage image;

    public Tree(String path) {
        try {
            image = ImageIO.read(Tree.class.getResourceAsStream(path));

        } catch (Exception ex) {
            System.out.println("Tree: " + ex.toString());
        }

    }

    public void paint(Graphics g) {

        g.drawImage(image, 150, 160, null);
    }
}
